package com.zc.commons.auth.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import org.springframework.security.core.GrantedAuthority;

/**
 * 系统角色
 */
@Data
@TableName(value = "system_role")
public class SystemRole implements GrantedAuthority {

    /**
     * ID
     */
    @TableId(type = IdType.INPUT)
    private String id;

    /**
     * 名称
     */
    private String roleName;

    /**
     * 编号
     */
    private String roleCode;


    @Override
    public String getAuthority() {
        return this.roleCode;
    }
}
